﻿<ResourceDictionary  xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
                    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
                    xmlns:PresentationOptions="http://schemas.microsoft.com/winfx/2006/xaml/presentation/options"
                    xmlns:sys="clr-namespace:System;assembly=mscorlib"
                    xmlns:System="clr-namespace:System;assembly=mscorlib"
                    xmlns:vsm="clr-namespace:System.Windows;assembly=PresentationFramework"
                    >
    <!-- Global Settings-->
    <ResourceDictionary.MergedDictionaries>
        <ResourceDictionary Source="Brushes.xaml" />
        <ResourceDictionary Source="Fonts.xaml" />
    </ResourceDictionary.MergedDictionaries>

    <ControlTemplate x:Key="ValidationToolTipTemplate">
        <Grid x:Name="Root"
              Margin="5,0"
              Opacity="0"
              RenderTransformOrigin="0,0">
            <Grid.RenderTransform>
                <TranslateTransform x:Name="xform"
                                    X="-25" />
            </Grid.RenderTransform>
            <vsm:VisualStateManager.VisualStateGroups>
                <vsm:VisualStateGroup x:Name="OpenStates">
                    <vsm:VisualStateGroup.Transitions>
                        <vsm:VisualTransition GeneratedDuration="0" />
                        <vsm:VisualTransition GeneratedDuration="0:0:0.2"
                                              To="Open">
                            <Storyboard>
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="X"
                                                               Storyboard.TargetName="xform">
                                    <SplineDoubleKeyFrame KeyTime="0:0:0.2"
                                                          Value="0" />
                                </DoubleAnimationUsingKeyFrames>
                                <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                               Storyboard.TargetName="Root">
                                    <SplineDoubleKeyFrame KeyTime="0:0:0.2"
                                                          Value="1" />
                                </DoubleAnimationUsingKeyFrames>
                            </Storyboard>
                        </vsm:VisualTransition>
                    </vsm:VisualStateGroup.Transitions>
                    <vsm:VisualState x:Name="Closed">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                           Storyboard.TargetName="Root">
                                <SplineDoubleKeyFrame KeyTime="0"
                                                      Value="0" />
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                    </vsm:VisualState>
                    <vsm:VisualState x:Name="Open">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="X"
                                                           Storyboard.TargetName="xform">
                                <SplineDoubleKeyFrame KeyTime="0"
                                                      Value="0" />
                            </DoubleAnimationUsingKeyFrames>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                           Storyboard.TargetName="Root">
                                <SplineDoubleKeyFrame KeyTime="0"
                                                      Value="1" />
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                    </vsm:VisualState>
                </vsm:VisualStateGroup>
            </vsm:VisualStateManager.VisualStateGroups>
            <Border Background="{StaticResource ValidationBrush1}"
                    CornerRadius="5"
                    Margin="4,4,-4,-4" />
            <Border Background="{StaticResource ValidationBrush2}"
                    CornerRadius="4"
                    Margin="3,3,-3,-3" />
            <Border Background="{StaticResource ValidationBrush3}"
                    CornerRadius="3"
                    Margin="2,2,-2,-2" />
            <Border Background="{StaticResource ValidationBrush4}"
                    CornerRadius="2"
                    Margin="1,1,-1,-1" />
            <Border Background="{StaticResource ValidationBrush5}"
                    CornerRadius="2" />
            <Border CornerRadius="2">
                <TextBlock Foreground="{StaticResource WhiteColorBrush}"
                           FontWeight="SemiBold"
                           MaxWidth="250"
                           Margin="8,4,8,4"
                           TextWrapping="Wrap"
                           Text="{Binding (Validation.Errors)[0].ErrorContent}"
                           UseLayoutRounding="false" />
            </Border>
        </Grid>
    </ControlTemplate>


    <Style TargetType="{x:Type Button}" x:Key="ControlCommandButton">
        <Setter Property="FontFamily" Value="Marlett"/>
        <Setter Property="VerticalAlignment" Value="Stretch"/>
        <Setter Property="Width" Value="30" />
        <Setter Property="Height" Value="25" />
        <Setter Property="BorderThickness" Value="0" ></Setter>
        <Setter Property="Margin" Value="0"></Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type Button}">
                    <Border x:Name="Border" >
                        <ContentPresenter Margin="0"
                             HorizontalAlignment="Center"
                             VerticalAlignment="Center"
                             RecognizesAccessKey="True" 
                             TextElement.FontWeight="Light" 
                             TextElement.FontSize="12"/>
                        <Border.Style>
                            <Style TargetType="Border">
                                <Style.Triggers>
                                    <Trigger Property="IsMouseOver" Value="True">
                                        <Setter Property="Background" Value="#FFCDE6F7"/>                                        
                                    </Trigger>
                                    <Trigger Property="IsMouseOver" Value="False">
                                        <Setter Property="Background" Value="{StaticResource WhiteColorBrush}"/>
                                    </Trigger>
                                </Style.Triggers>
                            </Style>
                        </Border.Style>
                    </Border>
                    <ControlTemplate.Triggers>
                        <Trigger Property="IsMouseOver" Value="False">
                            <Setter Property="Foreground" Value="{StaticResource LightGrayBrush}"/>
                        </Trigger>
                        <Trigger Property="IsMouseOver" Value="true">
                            <Setter Property="Foreground" Value="#FF2A8DD4"/>
                        </Trigger>
                        <!--<Trigger Property="IsKeyboardFocused" Value="true">
                            <Setter TargetName="Border" Property="BorderBrush" Value="#202020" />
                        </Trigger>
                        <Trigger Property="IsDefaulted" Value="true">
                            <Setter TargetName="Border" Property="BorderBrush" Value="#202020" />
                        </Trigger>
                        <Trigger Property="IsEnabled" Value="false">
                            <Setter TargetName="Border" Property="Background" Value="#EEEEEE" />
                            <Setter TargetName="Border" Property="BorderBrush" Value="#AAAAAA" />
                            <Setter Property="Foreground" Value="#888888"/>
                        </Trigger>-->
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--Control Label Style-->
    <Style x:Key="ControlLabelStyle"
           TargetType="TextBlock">
        <Setter Property="SnapsToDevicePixels"
                Value="true" />
        <Setter Property="Foreground"
                Value="{StaticResource LabelTextBrush}" />
        <Setter Property="FontFamily"
                Value="{StaticResource ContentFontFamily}" />
        <Setter Property="FontSize"
                Value="{StaticResource LabelFontSize}" />
        <Setter Property="TextOptions.TextHintingMode"
                Value="Animated" />
    </Style>

    <Style TargetType="DataGridRow" x:Key="GridRowStyle">
        <Style.Triggers>
            <Trigger Property="IsSelected" Value="True">
                <Setter Property="Background" Value="{StaticResource HightlightMetroBackground}"/>
                <Setter Property="Foreground" Value="Black"/>
            </Trigger>

        </Style.Triggers>
    </Style>

    <Style TargetType="DataGridCell" x:Key="GridCellStyle" >
        <Setter Property="BorderThickness" Value="0" />
        <Setter Property="Padding" Value="2,1,2,1"/>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="{x:Type DataGridCell}">
                    <Border Padding="{TemplateBinding Padding}" BorderBrush="{TemplateBinding BorderBrush}" BorderThickness="{TemplateBinding BorderThickness}" Background="{TemplateBinding Background}" SnapsToDevicePixels="True">
                        <ContentPresenter SnapsToDevicePixels="{TemplateBinding SnapsToDevicePixels}"/>
                    </Border>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Style.Triggers>
            <Trigger Property="IsSelected" Value="True">
                <Setter Property="Background" Value="{StaticResource HightlightMetroBackground}"/>
                <Setter Property="Foreground" Value="Black"/>
            </Trigger>
        </Style.Triggers>
    </Style>

    <Style x:Key="GridHeaderStyle" TargetType="{x:Type DataGridColumnHeader}" >
        <Setter Property="Background" Value="{StaticResource GrayBrush7}" />
        <Setter Property="BorderBrush" Value="{StaticResource ControlBorderBrush}"/>
        <Setter Property="BorderThickness" Value="0,0,0,1"/>
        <Setter Property="Padding" Value="4,0,0,0"/>
        <Style.Triggers>
            <Trigger Property="IsMouseOver" Value="True">
                <Setter Property="Background" Value="{StaticResource HightlightMetroBackground}" />
            </Trigger>
        </Style.Triggers>
    </Style>

    <Style x:Key="GridStyle" TargetType="{x:Type DataGrid}">
        <Setter Property="VerticalGridLinesBrush" Value="Gray"/>
        <Setter Property="Background" Value="White"/>
        <Setter Property="HorizontalGridLinesBrush" Value="#FFE3E3E3"/>
        <Setter Property="VerticalGridLinesBrush" Value="LightGray"/>
        <Setter Property="VerticalAlignment" Value="Stretch"/>
        <Setter Property="HorizontalAlignment" Value="Stretch"/>
        <Setter Property="BorderThickness" Value="0" />
        <Setter Property="ColumnHeaderStyle" Value="{StaticResource GridHeaderStyle}" />
        <Setter Property="RowStyle" Value="{StaticResource GridRowStyle}"/>
        <Setter Property="CellStyle" Value="{StaticResource GridCellStyle}"/>
    </Style>

    <Style x:Key="FindPanelCloseButtonStyle" TargetType="Button" BasedOn="{StaticResource ControlCommandButton}">
    </Style>

    <!--TextBox Style-->
    <Style TargetType="TextBox"
           x:Key="DefaultTextBoxStyle">
        <Setter Property="SnapsToDevicePixels"
                Value="true" />
        <Setter Property="FontFamily"
                Value="{StaticResource ContentFontFamily}" />
        <Setter Property="FontSize"
                Value="{StaticResource ContentFontSize}" />
        <Setter Property="BorderThickness"
                Value="1" />
        <Setter Property="FocusVisualStyle"
                Value="{x:Null}" />
        <Setter Property="MinHeight"
                Value="20" />
        <Setter Property="Background"
                Value="{StaticResource ControlBackgroundBrush}" />
        <Setter Property="Foreground"
                Value="{StaticResource TextBrush}" />
        <Setter Property="Padding"
                Value="0" />
        <Setter Property="BorderBrush"
                Value="{StaticResource TextBoxBorderBrush}" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="TextBox">
                    <Grid x:Name="RootElement">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0"
                                                         To="1"
                                                         Storyboard.TargetProperty="(UIElement.Opacity)"
                                                         Storyboard.TargetName="FocusRectangle" />
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                                       Storyboard.TargetName="DisabledVisualElement">
                                            <SplineDoubleKeyFrame KeyTime="0"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="ReadOnly">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                                       Storyboard.TargetName="ReadOnlyVisualElement">
                                            <SplineDoubleKeyFrame KeyTime="0"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0"
                                                         To="1"
                                                         Storyboard.TargetProperty="(UIElement.Opacity)"
                                                         Storyboard.TargetName="FocusRectangle" />
                                        <DoubleAnimation Duration="0"
                                                         To="1"
                                                         Storyboard.TargetProperty="(UIElement.Opacity)"
                                                         Storyboard.TargetName="FocusInnerRectangle" />
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused">
                                    <Storyboard />
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="ValidationStates">
                                <vsm:VisualState x:Name="Valid" />
                                <vsm:VisualState x:Name="InvalidUnfocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility"
                                                                       Storyboard.TargetName="ValidationErrorElement">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="InvalidFocused">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="Visibility"
                                                                       Storyboard.TargetName="ValidationErrorElement">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ObjectAnimationUsingKeyFrames Storyboard.TargetProperty="IsOpen"
                                                                       Storyboard.TargetName="validationTooltip">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <sys:Boolean>True</sys:Boolean>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Rectangle x:Name="Base"
                                   Stroke="{TemplateBinding BorderBrush}"
                                   StrokeThickness="{TemplateBinding BorderThickness}"
                                   Opacity="1"
                                   Fill="{StaticResource ControlBackgroundBrush}" />
                        <Rectangle x:Name="FocusRectangle"
                                   StrokeThickness="{TemplateBinding BorderThickness}"
                                   Opacity="0"
                                   Stroke="{StaticResource TextBoxMouseOverBorderBrush}" />
                        <Rectangle x:Name="FocusInnerRectangle"
                                   StrokeThickness="{TemplateBinding BorderThickness}"
                                   Opacity="0"
                                   Margin="1"
                                   Stroke="{StaticResource TextBoxMouseOverInnerBorderBrush}" />
                        <Grid Margin="0,1,0,0">
                            <Border x:Name="ReadOnlyVisualElement"
                                    Background="{StaticResource ReadOnlyBrush}"
                                    Opacity="0" />
                            <Grid>
                                <ScrollViewer x:Name="PART_ContentHost"
                                              BorderThickness="0"
                                              IsTabStop="False"
                                              Margin="4,0,4,2"
                                              VerticalAlignment="{TemplateBinding VerticalAlignment}"
                                              Background="{x:Null}" />
                            </Grid>
                        </Grid>
                        <Rectangle x:Name="DisabledVisualElement"
                                   Stroke="{StaticResource ControlsDisabledBrush}"
                                   StrokeThickness="{TemplateBinding BorderThickness}"
                                   Fill="{StaticResource ControlsDisabledBrush}"
                                   IsHitTestVisible="False"
                                   Opacity="0" />
                        <Border x:Name="ValidationErrorElement"
                                BorderBrush="{StaticResource ControlsValidationBrush}"
                                BorderThickness="1"
                                Visibility="Collapsed">
                            <ToolTipService.ToolTip>
                                <ToolTip x:Name="validationTooltip"
                                         IsHitTestVisible="True"
                                         DataContext="{Binding RelativeSource={RelativeSource TemplatedParent}}"
                                         Placement="Right"
                                         PlacementTarget="{Binding RelativeSource={RelativeSource TemplatedParent}}"
                                         Template="{StaticResource ValidationToolTipTemplate}" />
                            </ToolTipService.ToolTip>
                            <Grid Background="Transparent"
                                  HorizontalAlignment="Right"
                                  Height="12"
                                  Margin="1,-4,-4,0"
                                  VerticalAlignment="Top"
                                  Width="12">
                                <Path Data="M 1,0 L6,0 A 2,2 90 0 1 8,2 L8,7 z"
                                      Fill="{StaticResource ValidationBrush5}"
                                      Margin="1,3,0,0" />
                                <Path Data="M 0,0 L2,0 L 8,6 L8,8"
                                      Fill="{StaticResource WhiteColorBrush}"
                                      Margin="1,3,0,0" />
                            </Grid>
                        </Border>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>

    <!--Button Style-->
    <Style TargetType="Button"
           x:Key="DefaultButtonStyle">
        <Setter Property="SnapsToDevicePixels"
                Value="true" />
        <Setter Property="Background"
                Value="{StaticResource GrayBrush7}" />
        <Setter Property="BorderBrush"
                Value="{StaticResource TextBoxBorderBrush}" />
        <Setter Property="Foreground"
                Value="{StaticResource TextBrush}" />
        <Setter Property="FontFamily"
                Value="{StaticResource ContentFontFamily}" />
        <Setter Property="FontSize"
                Value="{StaticResource ContentFontSize}" />
        <Setter Property="Padding"
                Value="5,6" />
        <Setter Property="BorderThickness"
                Value="1" />
        <!--<Setter Property="IsTabStop"
                Value="False" />-->
        <Setter Property="Focusable"
                Value="True" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Button">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="MouseOverBorder">
                                            <EasingDoubleKeyFrame KeyTime="0"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="PressedBorder">
                                            <EasingDoubleKeyFrame KeyTime="0"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                                       Storyboard.TargetName="DisabledVisualElement">
                                            <SplineDoubleKeyFrame KeyTime="0"
                                                                  Value="0.7" />
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="contentPresenter">
                                            <EasingDoubleKeyFrame KeyTime="0"
                                                                  Value="0.3" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                            <vsm:VisualStateGroup x:Name="FocusStates">
                                <vsm:VisualState x:Name="Focused">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="FocusRectangle">
                                            <EasingDoubleKeyFrame KeyTime="0"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="FocusInnerRectangle">
                                            <EasingDoubleKeyFrame KeyTime="0"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>

                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Unfocused" />
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Border x:Name="Background"
                                BorderBrush="{TemplateBinding BorderBrush}"
                                BorderThickness="{TemplateBinding BorderThickness}"
                                Background="{TemplateBinding Background}"
                                CornerRadius="0" />
                        <Rectangle x:Name="DisabledVisualElement"
                                   Fill="{StaticResource ControlsDisabledBrush}"
                                   IsHitTestVisible="false"
                                   Opacity="0"
                                   RadiusY="0"
                                   RadiusX="0" />
                        <Border x:Name="MouseOverBorder"
                                Background="{StaticResource GrayBrush8}"
                                BorderThickness="{TemplateBinding BorderThickness}"
                                CornerRadius="0"
                                Opacity="0" />
                        <Border x:Name="PressedBorder"
                                Background="{StaticResource GrayBrush5}"
                                BorderThickness="{TemplateBinding BorderThickness}"
                                CornerRadius="0"
                                Opacity="0" />
                        <Rectangle x:Name="FocusRectangle"
                                   Stroke="{StaticResource TextBoxMouseOverInnerBorderBrush}"
                                   RadiusY="0"
                                   RadiusX="0"
                                   Margin="-1"
                                   Opacity="0" />
                        <Rectangle x:Name="FocusInnerRectangle"
                                   StrokeThickness="{TemplateBinding BorderThickness}"
                                   Stroke="{StaticResource TextBoxMouseOverBorderBrush}"
                                   RadiusX="0"
                                   RadiusY="0"
                                   Opacity="0" />
                        <ContentPresenter x:Name="contentPresenter"
                                          ContentTemplate="{TemplateBinding ContentTemplate}"
                                          Content="{TemplateBinding Content}"
                                          HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                          Margin="{TemplateBinding Padding}"
                                          VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                          RenderOptions.ClearTypeHint="Enabled" />
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


    <!--GridSplitter Style-->
    <Style TargetType="GridSplitter"
           x:Key="DefaultGridSplitterStyle">
        <Setter Property="Background"
                Value="{StaticResource GrayBrush7}" />
        <Setter Property="IsTabStop" Value="true" />
        <Setter Property="HorizontalAlignment"
                Value="Right" />
        <Setter Property="PreviewStyle">
            <Setter.Value>
                <Style TargetType="Control">
                    <Setter Property="Background"
                            Value="{StaticResource GrayBrush2}" />
                    <Setter Property="Template">
                        <Setter.Value>
                            <ControlTemplate TargetType="Control">
                                <Grid x:Name="Root"
                                      Opacity=".5">
                                    <Rectangle Fill="{TemplateBinding Background}" />
                                    <Grid x:Name="HorizontalTemplate"
                                          Height="6" />
                                    <Grid x:Name="VerticalTemplate"
                                          Visibility="Collapsed"
                                          Width="6" />
                                </Grid>
                            </ControlTemplate>
                        </Setter.Value>
                    </Setter>
                </Style>
            </Setter.Value>
        </Setter>
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="GridSplitter">
                    <Grid x:Name="Root"
                          IsHitTestVisible="{TemplateBinding IsEnabled}">
                        <VisualStateManager.VisualStateGroups>
                            <VisualStateGroup x:Name="CommonStates">
                                <VisualState x:Name="Normal" />
                                <VisualState x:Name="MouseOver" />
                                <VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0"
                                                         To="0.5"
                                                         Storyboard.TargetProperty="Opacity"
                                                         Storyboard.TargetName="Root" />
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                            <VisualStateGroup x:Name="FocusStates">
                                <VisualStateGroup.Transitions>
                                    <VisualTransition GeneratedDuration="0" />
                                </VisualStateGroup.Transitions>
                                <VisualState x:Name="Unfocused" />
                                <VisualState x:Name="Focused">
                                    <Storyboard>
                                        <DoubleAnimation Duration="0"
                                                         To="1"
                                                         Storyboard.TargetProperty="Opacity"
                                                         Storyboard.TargetName="FocusVisual" />
                                    </Storyboard>
                                </VisualState>
                            </VisualStateGroup>
                        </VisualStateManager.VisualStateGroups>
                        <Rectangle Fill="{TemplateBinding Background}"
                                   StrokeThickness="0" />
                        <Grid x:Name="HorizontalTemplate"
                              Height="10"
                              Visibility="Hidden">
                            <Border BorderThickness="0"
                                    BorderBrush="{StaticResource TextBoxBorderBrush}">
                                <Canvas Height="6"
                                        VerticalAlignment="Center"
                                        Width="12">
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="1"
                                          Canvas.Top="0.29">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="1.525">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="1"
                                          Canvas.Top="3.463">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="4.698">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="4.006"
                                          Canvas.Top="0.29">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="1.525"
                                          Canvas.Left="3.006">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="4.006"
                                          Canvas.Top="3.463">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="4.698"
                                          Canvas.Left="3.006">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="6.845"
                                          Canvas.Top="0.29">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="1.525"
                                          Canvas.Left="5.845">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="6.845"
                                          Canvas.Top="3.463">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="4.698"
                                          Canvas.Left="5.845">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="9.851"
                                          Canvas.Top="0.29">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="1.525"
                                          Canvas.Left="8.851">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="9.851"
                                          Canvas.Top="3.463">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="4.698"
                                          Canvas.Left="8.851">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                </Canvas>
                            </Border>
                        </Grid>
                        <Grid x:Name="VerticalTemplate"
                              Visibility="Visible"
                              Width="10">
                            <Border BorderThickness="0"
                                    BorderBrush="{StaticResource TextBoxBorderBrush}">
                                <Canvas Width="6"
                                        Height="12">
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="1"
                                          Canvas.Top="0.29">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="1.525">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="1"
                                          Canvas.Top="3.463">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="4.698">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="1"
                                          Canvas.Top="6.302">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="7.537">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="1"
                                          Canvas.Top="8.974">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="10.209">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="4.006"
                                          Canvas.Top="0.29">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="1.525"
                                          Canvas.Left="3.006">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="4.006"
                                          Canvas.Top="3.463">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="4.698"
                                          Canvas.Left="3.006">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="4.006"
                                          Canvas.Top="6.302">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="7.537"
                                          Canvas.Left="3.006">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M405.14063,248.65625 L405.14063,250.01588"
                                          Fill="White"
                                          Height="2.36"
                                          Stretch="Fill"
                                          UseLayoutRounding="False"
                                          Width="1"
                                          StrokeThickness="0.25"
                                          Canvas.Left="4.006"
                                          Canvas.Top="8.974">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                    <Path Data="M404.76563,249.82813 L406.984,249.82813"
                                          Fill="White"
                                          Height="0.25"
                                          Stretch="Fill"
                                          StrokeThickness="0.25"
                                          UseLayoutRounding="False"
                                          Width="2.468"
                                          Canvas.Top="10.209"
                                          Canvas.Left="3.006">
                                        <Path.Stroke>
                                            <SolidColorBrush Color="{StaticResource Gray2}" />
                                        </Path.Stroke>
                                    </Path>
                                </Canvas>
                            </Border>
                        </Grid>
                        <Rectangle x:Name="FocusVisual"
                                   IsHitTestVisible="false"
                                   Opacity="0"
                                   StrokeThickness="0">
                            <Rectangle.Stroke>
                                <SolidColorBrush Color="{StaticResource HighlightDarkColor}" />
                            </Rectangle.Stroke>
                        </Rectangle>
                    </Grid>
                    <ControlTemplate.Triggers>
                        <Trigger Property="ResizeDirection"
                                 Value="Rows">
                            <Setter Property="Visibility"
                                    TargetName="VerticalTemplate"
                                    Value="Hidden" />
                            <Setter Property="Visibility"
                                    TargetName="HorizontalTemplate"
                                    Value="Visible" />
                        </Trigger>
                    </ControlTemplate.Triggers>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
        <Setter Property="Foreground"
                Value="{StaticResource TextBrush}" />
    </Style>


    <!--ScrollBar Styles & Templates-->
    <ControlTemplate x:Key="HorizontalScrollBarTemplate"
                     TargetType="ScrollBar">
        <Grid x:Name="Root" Background="{StaticResource GrayBrush7}">
            <Grid.Resources>
                <ControlTemplate x:Key="RepeatButtonTemplate"
                                 TargetType="RepeatButton">
                    <Grid x:Name="Root"
                          Background="Transparent">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                    </Grid>
                </ControlTemplate>
                <ControlTemplate x:Key="HorizontalIncrementTemplate"
                                 TargetType="RepeatButton">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="HoverPath">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Blur">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard />
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Root">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Path Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z "
                              Height="6"
                              Stretch="Uniform"
                              Width="4">
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource Gray2}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="HoverPath"
                              Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z "
                              Height="6"
                              Stretch="Uniform"
                              Width="4"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="1,1,0,0">
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="Blur"
                              Data="F1 M 511.047,352.682L 511.047,342.252L 517.145,347.467L 511.047,352.682 Z "
                              Height="6"
                              Stretch="Uniform"
                              Width="4"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="1,1,0,0">
                            <Path.Effect>
                                <BlurEffect />
                            </Path.Effect>
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Rectangle x:Name="DisabledElement"
                                   Fill="{StaticResource WhiteColorBrush}"
                                   Opacity="0"
                                   RadiusY="2"
                                   RadiusX="2" />
                    </Grid>
                </ControlTemplate>
                <ControlTemplate x:Key="HorizontalDecrementTemplate"
                                 TargetType="RepeatButton">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="HoverPath">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Blur">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard />
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Root">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Path Data="F1 M 110.692,342.252L 110.692,352.682L 104.594,347.467L 110.692,342.252 Z "
                              Height="6"
                              Stretch="Uniform"
                              Width="4">
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource Gray2}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="HoverPath"
                              Data="F1 M 110.692,342.252L 110.692,352.682L 104.594,347.467L 110.692,342.252 Z "
                              Height="6"
                              Stretch="Uniform"
                              Width="4"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="0,1,0,0">
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="Blur"
                              Data="F1 M 110.692,342.252L 110.692,352.682L 104.594,347.467L 110.692,342.252 Z "
                              Height="6"
                              Stretch="Uniform"
                              Width="4"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="0,1,0,0">
                            <Path.Effect>
                                <BlurEffect />
                            </Path.Effect>
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                    </Grid>
                </ControlTemplate>
                <ControlTemplate x:Key="HorizontalThumbTemplate"
                                 TargetType="Thumb">
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="MouseOverRectangle">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="PressedRectangle">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                                       Storyboard.TargetName="ThumbVisual">
                                            <SplineDoubleKeyFrame KeyTime="0:0:0"
                                                                  Value="0" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid x:Name="ThumbVisual"
                              Margin="0,1,0,1">
                            <Rectangle x:Name="Background"
                                       StrokeThickness="1"
                                       Fill="{StaticResource ThumbBrush}" />
                            <Rectangle x:Name="MouseOverRectangle"
                                       StrokeThickness="1"
                                       Opacity="0"
                                       Fill="{StaticResource BlackBrush}" />
                            <Rectangle x:Name="PressedRectangle"
                                       StrokeThickness="1"
                                       Opacity="0"
                                       Fill="{StaticResource BlackBrush}" />
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Grid.Resources>
            <vsm:VisualStateManager.VisualStateGroups>
                <vsm:VisualStateGroup x:Name="CommonStates">
                    <vsm:VisualState x:Name="Normal" />
                    <vsm:VisualState x:Name="MouseOver" />
                    <vsm:VisualState x:Name="Disabled">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                           Storyboard.TargetName="Root">
                                <SplineDoubleKeyFrame KeyTime="0"
                                                      Value="0.5" />
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                    </vsm:VisualState>
                </vsm:VisualStateGroup>
            </vsm:VisualStateManager.VisualStateGroups>
            <Grid x:Name="HorizontalRoot"
                  Height="11">
                <Grid.ColumnDefinitions>
                    <ColumnDefinition Width="Auto" />
                    <ColumnDefinition Width="*" />
                    <ColumnDefinition Width="Auto" />
                </Grid.ColumnDefinitions>

                <Border BorderThickness="0,0,0,1"
                        Grid.RowSpan="1"
                        Margin="0,0,0,-1"
                        Grid.ColumnSpan="3"
                        Visibility="Collapsed">
                    <Border.BorderBrush>
                        <SolidColorBrush Color="{StaticResource Gray4}"
                                         PresentationOptions:Freeze="True" />
                    </Border.BorderBrush>
                </Border>

                <RepeatButton x:Name="HorizontalSmallDecrease"
                              Grid.Column="0"
                              Interval="50"
                              IsTabStop="False"
                              Width="16"
                              Margin="1"
                              Template="{StaticResource HorizontalDecrementTemplate}"
                              Command="ScrollBar.LineLeftCommand"
                              Visibility="{Binding ElementName=PART_Track, Path=Visibility}" />

                <Track x:Name="PART_Track"
                       Grid.Column="1"
                       Orientation="Horizontal">
                    <Track.DecreaseRepeatButton>
                        <RepeatButton x:Name="HorizontalLargeDecrease"
                                      IsTabStop="False"
                                      Interval="50"
                                      Template="{StaticResource RepeatButtonTemplate}"
                                      Command="ScrollBar.PageLeftCommand" />
                    </Track.DecreaseRepeatButton>
                    <Track.Thumb>
                        <Thumb x:Name="HorizontalThumb"
                               Background="{TemplateBinding Background}"
                               Grid.Column="2"
                               MinWidth="100"
                               Template="{StaticResource HorizontalThumbTemplate}"                               
                               HorizontalAlignment="Stretch" />
                    </Track.Thumb>
                    <Track.IncreaseRepeatButton>
                        <RepeatButton x:Name="HorizontalLargeIncrease"
                                      IsTabStop="False"
                                      Interval="50"
                                      Template="{StaticResource RepeatButtonTemplate}"
                                      Command="ScrollBar.PageRightCommand" />
                    </Track.IncreaseRepeatButton>
                </Track>

                <RepeatButton x:Name="HorizontalSmallIncrease"
                              Grid.Column="2"
                              IsTabStop="False"
                              Interval="50"
                              Width="16"
                              Margin="1"
                              Template="{StaticResource HorizontalIncrementTemplate}"
                              Command="ScrollBar.LineRightCommand"
                              Visibility="{Binding ElementName=PART_Track, Path=Visibility}" />
            </Grid>
        </Grid>
    </ControlTemplate>

    <ControlTemplate x:Key="VerticalScrollBarTemplate"
                     TargetType="ScrollBar">
        <Grid x:Name="Root" Background="{StaticResource GrayBrush7}">
            <Grid.Resources>
                <ControlTemplate x:Key="RepeatButtonTemplate"
                                 TargetType="RepeatButton">
                    <Grid x:Name="Root"
                          Background="Transparent">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                    </Grid>
                </ControlTemplate>
                <ControlTemplate x:Key="VerticalIncrementTemplate"
                                 TargetType="RepeatButton">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="HoverPath">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Blur">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard />
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Root">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Path Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z "
                              Height="4"
                              Stretch="Uniform"
                              Width="6">
                            <Path.Fill>
                                <SolidColorBrush x:Name="ButtonColor"
                                                 Color="{StaticResource Gray3}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="HoverPath"
                              Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z "
                              Height="4"
                              Stretch="Uniform"
                              Width="6"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="1,0,0,0">
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="Blur"
                              Data="F1 M 531.107,321.943L 541.537,321.943L 536.322,328.042L 531.107,321.943 Z "
                              Height="4"
                              Stretch="Uniform"
                              Width="6"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="1,0,0,0">
                            <Path.Effect>
                                <BlurEffect />
                            </Path.Effect>
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Rectangle x:Name="DisabledElement"
                                   Fill="{StaticResource WhiteColorBrush}"
                                   Opacity="0"
                                   RadiusY="2"
                                   RadiusX="2" />
                    </Grid>
                </ControlTemplate>
                <ControlTemplate x:Key="VerticalDecrementTemplate"
                                 TargetType="RepeatButton">
                    <Grid x:Name="Root">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="HoverPath">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Blur">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard />
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="Root">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="0.5" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Rectangle x:Name="Background"
                                   Fill="{StaticResource ControlBackgroundBrush}"
                                   Opacity="0"
                                   RadiusY="2"
                                   RadiusX="2"
                                   StrokeThickness="1" />
                        <Rectangle x:Name="BackgroundMouseOver"
                                   Fill="{StaticResource HighlightBrush}"
                                   Opacity="0"
                                   RadiusY="2"
                                   RadiusX="2" />
                        <Rectangle x:Name="BackgroundPressed"
                                   Fill="{StaticResource HighlightBrush}"
                                   Opacity="0"
                                   RadiusY="2"
                                   RadiusX="2" />
                        <Rectangle x:Name="BackgroundGradient"
                                   Fill="{StaticResource TransparentWhiteBrush}"
                                   Margin="1"
                                   Opacity="0"
                                   RadiusY="1"
                                   RadiusX="1"
                                   Stroke="{StaticResource ControlBackgroundBrush}"
                                   StrokeThickness="1" />
                        <Rectangle x:Name="Highlight"
                                   IsHitTestVisible="false"
                                   Margin="1"
                                   Opacity="0"
                                   RadiusY="1"
                                   RadiusX="1"
                                   Stroke="{StaticResource HighlightBrush}"
                                   StrokeThickness="1" />
                        <Path Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z "
                              Height="4"
                              Stretch="Uniform"
                              Width="6">
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource Gray2}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="HoverPath"
                              Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z "
                              Height="4"
                              Stretch="Uniform"
                              Width="6"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="1,0,0,0">
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                        <Path x:Name="Blur"
                              Data="F1 M 541.537,173.589L 531.107,173.589L 536.322,167.49L 541.537,173.589 Z "
                              Height="4"
                              Stretch="Uniform"
                              Width="6"
                              UseLayoutRounding="False"
                              Opacity="0"
                              Margin="1,0,0,0">
                            <Path.Effect>
                                <BlurEffect />
                            </Path.Effect>
                            <Path.Fill>
                                <SolidColorBrush Color="{StaticResource BlackColor}"
                                                 PresentationOptions:Freeze="True" />
                            </Path.Fill>
                        </Path>
                    </Grid>
                </ControlTemplate>
                <ControlTemplate x:Key="VerticalThumbTemplate"
                                 TargetType="Thumb" >
                    <Grid>
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="MouseOverRectangle">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>

                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="PressedRectangle">
                                            <EasingDoubleKeyFrame KeyTime="0:0:0.1"
                                                                  Value="1" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                                       Storyboard.TargetName="ThumbVisual">
                                            <SplineDoubleKeyFrame KeyTime="0:0:0"
                                                                  Value="0" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>
                        <Grid x:Name="ThumbVisual"
                              Margin="1,0,1,0">
                            <Rectangle x:Name="Background"
                                       StrokeThickness="1"
                                       Fill="{StaticResource ThumbBrush}" />
                            <Rectangle x:Name="MouseOverRectangle"
                                       StrokeThickness="1"
                                       Opacity="0"
                                       Fill="{StaticResource BlackBrush}" />
                            <Rectangle x:Name="PressedRectangle"
                                       StrokeThickness="1"
                                       Opacity="0"
                                       Fill="{StaticResource BlackBrush}" />
                        </Grid>
                    </Grid>
                </ControlTemplate>
            </Grid.Resources>
            <vsm:VisualStateManager.VisualStateGroups>
                <vsm:VisualStateGroup x:Name="CommonStates">
                    <vsm:VisualState x:Name="Normal" />
                    <vsm:VisualState x:Name="MouseOver" />
                    <vsm:VisualState x:Name="Disabled">
                        <Storyboard>
                            <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="Opacity"
                                                           Storyboard.TargetName="Root">
                                <SplineDoubleKeyFrame KeyTime="0"
                                                      Value="0.5" />
                            </DoubleAnimationUsingKeyFrames>
                        </Storyboard>
                    </vsm:VisualState>
                </vsm:VisualStateGroup>
            </vsm:VisualStateManager.VisualStateGroups>
            <Grid x:Name="VerticalRoot"
                  Width="11">
                <Grid.RowDefinitions>
                    <RowDefinition Height="Auto" />
                    <RowDefinition Height="*" />
                    <RowDefinition Height="Auto" />
                </Grid.RowDefinitions>

                <Border BorderThickness="0,0,1,0"
                        Margin="0,0,-1,0"
                        Grid.RowSpan="3"
                        Visibility="Collapsed">
                    <Border.BorderBrush>
                        <SolidColorBrush Color="{StaticResource Gray4}"
                                         PresentationOptions:Freeze="True" />
                    </Border.BorderBrush>
                </Border>

                <RepeatButton x:Name="VerticalSmallDecrease"
                              Grid.Row="0"
                              IsTabStop="False"
                              Interval="50"
                              Height="16"
                              Margin="1"
                              Template="{StaticResource VerticalDecrementTemplate}"
                              Command="ScrollBar.LineUpCommand"
                              Visibility="{Binding ElementName=PART_Track, Path=Visibility}" />

                <Track x:Name="PART_Track"
                       Grid.Row="1"
                       IsDirectionReversed="True"
                       Orientation="Vertical">
                    <Track.Resources>
                        <!-- Set the Thumb's minimum height to 50.
            The Thumb's minimum height is half the
            value of VerticalScrollBarButtonHeightKey. -->
                        <sys:Double 
                x:Key="{x:Static SystemParameters.VerticalScrollBarButtonHeightKey}">
                            100
                        </sys:Double>
                    </Track.Resources>
                    <Track.DecreaseRepeatButton>
                        <RepeatButton x:Name="VerticalLargeDecrease"
                                      Interval="50"
                                      IsTabStop="False"
                                      Template="{StaticResource RepeatButtonTemplate}"
                                      Command="ScrollBar.PageUpCommand" />
                    </Track.DecreaseRepeatButton>
                    <Track.Thumb>
                        <Thumb x:Name="VerticalThumb"
                               Height="Auto"
                               MinHeight="100"
                               Template="{StaticResource VerticalThumbTemplate}"
                               VerticalAlignment="Stretch" />
                    </Track.Thumb>
                    <Track.IncreaseRepeatButton>
                        <RepeatButton x:Name="VerticalLargeIncrease"
                                      IsTabStop="False"
                                      Interval="50"
                                      Template="{StaticResource RepeatButtonTemplate}"
                                      Command="ScrollBar.PageDownCommand" />
                    </Track.IncreaseRepeatButton>
                </Track>

                <RepeatButton x:Name="VerticalSmallIncrease"
                              Grid.Row="2"
                              IsTabStop="False"
                              Interval="50"
                              Height="16"
                              Margin="1"
                              Template="{StaticResource VerticalIncrementTemplate}"
                              Command="ScrollBar.LineDownCommand"
                              Visibility="{Binding ElementName=PART_Track, Path=Visibility}" />
            </Grid>
        </Grid>
    </ControlTemplate>

    <Style x:Key="DefaultScrollBarStyle"
           TargetType="ScrollBar">
        <Setter Property="OverridesDefaultStyle"
                Value="True" />
        <Setter Property="SnapsToDevicePixels"
                Value="True" />
        <Setter Property="Foreground"
                Value="{StaticResource TextBrush}" />
        <Setter Property="Background"
                Value="{StaticResource ControlBackgroundBrush}" />
        <Setter Property="MinWidth"
                Value="20" />
        <Setter Property="MinHeight"
                Value="20" />
        <Setter Property="IsTabStop"
                Value="False" />
        <Style.Triggers>
            <Trigger Property="Orientation"
                     Value="Horizontal">
                <Setter Property="Width"
                        Value="Auto" />
                <Setter Property="Template"
                        Value="{StaticResource HorizontalScrollBarTemplate}" />
            </Trigger>
            <Trigger Property="Orientation"
                     Value="Vertical">
                <Setter Property="Height"
                        Value="Auto" />
                <Setter Property="Template"
                        Value="{StaticResource VerticalScrollBarTemplate}" />
            </Trigger>
        </Style.Triggers>
    </Style>

    <!--HyperlinkButton Style-->
    <Style TargetType="Button"
           x:Key="DefaultHyperlinkButtonStyle">
        <Setter Property="SnapsToDevicePixels"
                Value="true" />
        <Setter Property="Foreground"
                Value="{StaticResource HighlightBrush}" />
        <Setter Property="FontFamily"
                Value="{StaticResource ContentFontFamily}" />
        <Setter Property="FontSize"
                Value="{StaticResource HyperlinkFontSize}" />
        <Setter Property="Padding"
                Value="2,0,2,0" />
        <Setter Property="Cursor"
                Value="Hand" />
        <Setter Property="HorizontalContentAlignment"
                Value="Left" />
        <Setter Property="VerticalContentAlignment"
                Value="Top" />
        <Setter Property="Background"
                Value="Transparent" />
        <Setter Property="IsTabStop"
                Value="False" />
        <Setter Property="Focusable"
                Value="False" />
        <Setter Property="Template">
            <Setter.Value>
                <ControlTemplate TargetType="Button">
                    <Grid Background="{TemplateBinding Background}"
                          Cursor="{TemplateBinding Cursor}">
                        <vsm:VisualStateManager.VisualStateGroups>
                            <vsm:VisualStateGroup x:Name="CommonStates">
                                <vsm:VisualState x:Name="Normal" />
                                <vsm:VisualState x:Name="MouseOver">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0"
                                                                       Storyboard.TargetProperty="Visibility"
                                                                       Storyboard.TargetName="UnderlineTextBlock">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <ColorAnimationUsingKeyFrames Storyboard.TargetName="ContentPresenterWrapperColor"
                                                                      Storyboard.TargetProperty="Color">
                                            <EasingColorKeyFrame KeyTime="0"
                                                                 Value="{StaticResource AccentColorLightBlue}" />
                                        </ColorAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Pressed">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0"
                                                                       Storyboard.TargetProperty="Visibility"
                                                                       Storyboard.TargetName="UnderlineTextBlock">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                                <vsm:VisualState x:Name="Disabled">
                                    <Storyboard>
                                        <ObjectAnimationUsingKeyFrames Duration="0"
                                                                       Storyboard.TargetProperty="Visibility"
                                                                       Storyboard.TargetName="DisabledOverlay">
                                            <DiscreteObjectKeyFrame KeyTime="0">
                                                <DiscreteObjectKeyFrame.Value>
                                                    <Visibility>Visible</Visibility>
                                                </DiscreteObjectKeyFrame.Value>
                                            </DiscreteObjectKeyFrame>
                                        </ObjectAnimationUsingKeyFrames>
                                        <DoubleAnimationUsingKeyFrames Storyboard.TargetProperty="(UIElement.Opacity)"
                                                                       Storyboard.TargetName="contentPresenter">
                                            <EasingDoubleKeyFrame KeyTime="0"
                                                                  Value="0" />
                                        </DoubleAnimationUsingKeyFrames>
                                    </Storyboard>
                                </vsm:VisualState>
                            </vsm:VisualStateGroup>
                        </vsm:VisualStateManager.VisualStateGroups>

                        <TextBlock x:Name="UnderlineTextBlock"
                                   HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                   VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                   Margin="{TemplateBinding Padding}"
                                   Text="{TemplateBinding Content}"
                                   TextDecorations="Underline"
                                   Visibility="Collapsed"
                                   FontSize="{TemplateBinding FontSize}">
                            <TextBlock.Foreground>
                                <SolidColorBrush Color="{StaticResource AccentColorBlue}"
                                                 PresentationOptions:Freeze="True" />
                            </TextBlock.Foreground>
                        </TextBlock>
                        <TextBlock x:Name="DisabledOverlay"
                                   Foreground="{StaticResource DisabledForegroundBrush}"
                                   HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                   VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                   Margin="{TemplateBinding Padding}"
                                   Text="{TemplateBinding Content}"
                                   Visibility="Collapsed"
                                   FontSize="{TemplateBinding FontSize}" />

                        <ContentControl FontSize="{TemplateBinding FontSize}"
                                        IsTabStop="{TemplateBinding IsTabStop}">
                            <ContentControl.Foreground>
                                <SolidColorBrush x:Name="ContentPresenterWrapperColor"
                                                 Color="{StaticResource AccentColorBlue}"
                                                 PresentationOptions:Freeze="True" />
                            </ContentControl.Foreground>
                            <TextBlock x:Name="contentPresenter"
                                       Text="{TemplateBinding Content}"
                                       HorizontalAlignment="{TemplateBinding HorizontalContentAlignment}"
                                       VerticalAlignment="{TemplateBinding VerticalContentAlignment}"
                                       Margin="{TemplateBinding Padding}"
                                       FontSize="{TemplateBinding FontSize}" />
                        </ContentControl>
                    </Grid>
                </ControlTemplate>
            </Setter.Value>
        </Setter>
    </Style>


    <Style TargetType="Button"
           BasedOn="{StaticResource DefaultButtonStyle}" />

    <Style TargetType="TextBox"
           BasedOn="{StaticResource DefaultTextBoxStyle}" />

    <Style TargetType="GridSplitter"
           BasedOn="{StaticResource DefaultGridSplitterStyle}" />

    <Style TargetType="ScrollBar"
           BasedOn="{StaticResource DefaultScrollBarStyle}" />

</ResourceDictionary>